package cn.fun.spring4.chapter3.demo;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.web.context.support.AnnotationConfigWebApplicationContext;

/**
 * @author zhangxf
 * @title Main
 * @date 2018/2/28
 * @description
 */
public class Main {

    public static void main(String[] args){
        AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(Config.class);
        UseHelloService bean = context.getBean(UseHelloService.class);
        bean.sayHello("jack");
        context.close();
    }
}
